package Zy.temo2;

public class Student extends Person{
    private String no;
    private String scoreEn;
    private String scoreMath;
    private String scoreChinese;

    public Student(String name, int age, String sex) {
        super(name, age, sex);

    }

    public String getNo() {
        return no;
    }

    public void setNo(String no) {
        this.no = no;
    }

    public String getScoreEn() {
        return scoreEn;
    }

    public void setScoreEn(String scoreEn) {
        this.scoreEn = scoreEn;
    }

    public String getScoreMath() {
        return scoreMath;
    }

    public void setScoreMath(String scoreMath) {
        this.scoreMath = scoreMath;
    }

    public String getScoreChinese() {
        return scoreChinese;
    }

    public void setScoreChinese(String scoreChinese) {
        this.scoreChinese = scoreChinese;
    }

    public void getaver(){
        double aver = (Double.parseDouble(scoreEn) +
                Double.parseDouble(scoreMath) +
                Double.parseDouble(scoreChinese)) / 3;
        System.out.println("平均成绩为：" + aver);
    }
    public void getmax(){
        double max;
    }

    public void getmin(){
        double min;
    }

    @Override
    public String toString() {
        return "Student{" +
                "no='" + no + '\'' +
                ", scoreEn='" + scoreEn + '\'' +
                ", scoreMath='" + scoreMath + '\'' +
                ", scoreChinese='" + scoreChinese + '\'' +
                '}';
    }


}
